<div style="width:90%; margin:40px auto 60px auto;">
	<div class="panel panel-default">
		<div class="panel-heading" style="padding:3px 15px;text-align:right;">
			<div style="width:50%;float:left;margin-top:4px;font-size:18px;">PONENTES</div>
			<button data-toggle="modal" data-target="#editModal" class="btn btn-primary btn-sm" type="button">
				<span class="glyphicon glyphicon-plus-sign"></span> Agregar Ponente
			</button>
		</div>
		<div class="panel-body" style="padding-bottom:10px;">
			<table cellpadding="0" cellspacing="0" border="0" id="example" class="table table-striped table-bordered">
				<thead>
					<tr>
						<th style="text-align: center;">NOMBRE</th>
						<th style="text-align: center;">APELLIDO</th>
						<th style="text-align: center;">DNI</th>
						<th style="text-align: center;">OPCIONES</th>
					</tr>
				</thead>
				<tbody>
				<?php foreach ($ponentes as $p) { ?>
					<tr>
						<td><?php echo $p['Ponente']['nombre']; ?></td>
						<td><?php echo $p['Ponente']['apellido']; ?></td>
						<td><?php echo $p['Ponente']['dni']; ?></td>
						<td style="text-align: center" id="options">
							<a style="text-decoration:none;" href="../Ponentes/editar?id=<?php echo $p['Ponente']['id']; ?>" title="Editar" data-toggle="tooltip" data-placement="left" data-delay="300" >
								<button class="btn btn-success btn-xs" type="button">
									<span class="glyphicon glyphicon-edit"></span>
								</button>
							</a>
							<a href="../Ponentes/borrar?id=<?php echo $p['Ponente']['id']; ?>" onclick="return confirm('¿Desea Eliminar este Ponente?');" title="Borrar" data-toggle="tooltip" data-placement="right" data-delay="300" >
								<button type="button" class="btn btn-danger btn-xs">
									<span class="glyphicon glyphicon-trash"></span>
								</button>
							</a>
						</td>
					</tr>
				<?php } ?>
				</tbody>
			</table>
		</div>
	</div>
</div>
<div class="modal fade" id="editModal" tabindex="-1" role="dialog" aria-labelledby="editModalLabel" aria-hidden="true">
	<div class="modal-dialog">
		<div class="modal-content">
      		<form action="../Ponentes/listar" method="post" class="form-horizontal" role="form">
	        	<div class="modal-header">
	          		<button type="button" class="close" data-dismiss="modal" aria-hidden="true">&times;</button>
	          		<h4 class="modal-title" style="text-align:center;color:#194D89;">AGREGAR PONENTE</h4>
	        	</div>
	        	<div class="modal-body">
					<div class="form-group">
				    	<label style="text-align:right;padding-right:0;" for="input2" class="col-lg-2 control-label">Nombre</label>
				    	<div class="col-lg-10">
				      		<input name="data[Ponente][nombre]" type="text" class="form-control" id="input2" placeholder="Nombre">
				    	</div>
				  	</div>
				  	<div class="form-group">
				    	<label style="text-align:right;padding-right:0;" for="inputPassword" class="col-lg-2 control-label">Apellido</label>
				    	<div class="col-lg-10">
				      		<input name="data[Ponente][apellido]" type="text" class="form-control" id="inputPassword" placeholder="Apellido">
				    	</div>
				  	</div>
				  	<div class="form-group">
				    	<label style="text-align:right;padding-right:0;" for="input3" class="col-lg-2 control-label">DNI</label>
				    	<div class="col-lg-10">
				      		<input name="data[Ponente][dni]" type="text" class="form-control" id="input3" placeholder="DNI">
				    	</div>
				  	</div>
				</div>
	        	<div class="modal-footer">
	          		<button type="button" class="btn btn-default" data-dismiss="modal">Cancelar</button>
	          		<input type="submit" class="btn btn-primary" value="Guardar"/>
	        	</div>
			</form>
		</div><!-- /.modal-content -->
    </div><!-- /.modal-dialog -->
</div>
<script>
	$('#options a').tooltip()
</script>